package com.dfbz.demo01_OutputStream;

import java.io.FileOutputStream;
import java.io.OutputStream;

/**
 * @author lscl
 * @version 1.0
 * @intro:
 */
public class Demo05_偏移量写出中文问题 {
    public static void main(String[] args) throws Exception {

        OutputStream os = new FileOutputStream("001.txt");

        //  00000000 00000000 00000000
        String str = "我是中国人";
        byte[] data = str.getBytes();

        os.write(data,0,2);
        os.close();
    }
}
